package com.xt.LibaryDeskManager.service;

import com.xt.LibaryDeskManager.dto.SeatDto;
import com.xt.LibaryDeskManager.vo.SeatVo;

import java.util.List;

public interface SeatService {

    /**
     * 获得所有座位
     * @return
     * @throws Exception
     */
    List<SeatDto> selectAll(String seatNo)throws Exception;
    /**
     * 获得指定教师所管理的座位信息
     * @return
     * @throws Exception
     */
    List<SeatDto> selectAll(Integer teacherNo,String seatNo)throws Exception;

    /**
     * 获取座位总数
     * @return
     * @throws Exception
     */
    int getCount()throws  Exception;

    /**
     * 更新座位信息
     * @param seatVo
     * @return
     * @throws Exception
     */
    int updateSeat(SeatVo seatVo) throws Exception;

    /**
     * 查找当前房间最后一个座位编号
     * @param seatNo
     * @return
     * @throws Exception
     */
    String getAvailableSeatNumber(String seatNo) throws Exception;

    /**
     * 添加座位信息
     * @param seatVo
     * @return
     * @throws Exception
     */
    int addSeat(SeatVo seatVo) throws Exception;

    /**
     * 删除座位信息
     * @param seatNo
     * @return
     * @throws Exception
     */
    int deleteSeat(String seatNo) throws Exception;

    /**
     * 更新座位状态
     * @param seatNo
     * @param i
     * @return
     */
    int updateSeatStatue(String seatNo, int i)throws Exception;

    /**
     * 根据座位号查找座位信息
     * @param seatNo
     * @return
     * @throws Exception
     */
    SeatDto getSeatBySeatNo(String seatNo)throws Exception;

    /**
     * 将预约状态清0,添加当天状态
     * @throws Exception
     * @return
     */
    int updateSeat()throws Exception;
}
